翻訳と辞書
Words near each other
・ String Quartet No. 3 (Dvořák)
・ String Quartet No. 3 (Mendelssohn)
・ String Quartet No. 3 (Nielsen)
・ String Quartet No. 3 (Piston)
・ String Quartet No. 3 (Rochberg)
・ String Quartet No. 3 (Rouse)
・ String Quartet No. 3 (Schubert)
・ String Quartet No. 3 (Shostakovich)
・ String Quartet No. 3 (Spohr)
・ String girdling Earth
・ String grammar
・ String graph
・ String group
・ String instrument
・ String instrument repertoire
String interning
・ String interpolation
・ String kernel
・ String Lake
・ String Lake Comfort Station
・ String Lake Trail
・ String Lakes
・ String literal
・ String metric
・ String noise
・ String octet
・ String of Hits
・ String of Pain
・ String of pearls
・ String of Pearls (Indian Ocean)


Dictionary Lists
翻訳と辞書 辞書検索 [ 開発暫定版 ]
スポンサード リンク

String interning : ウィキペディア英語版
String interning

In computer science, string interning is a method of storing only one copy of each distinct string value, which must be immutable. Interning strings makes some string processing tasks more time- or space-efficient at the cost of requiring more time when the string is created or interned. The distinct values are stored in a string intern pool.
The single copy of each string is called its 'intern' and is typically looked up by a method of the string class, for example in Java. All compile-time constant strings in Java are automatically interned using this method.〔(Java expressions )〕
String interning is supported by some modern object-oriented programming languages, including Python, PHP (since 5.4), Lua,〔(Immutable objects in Lua )〕 Ruby (with its symbols), Java and .NET languages.〔(Immutable objects in .NET )〕 Lisp, Scheme, and Smalltalk are among the languages with a symbol type that are basically interned strings. The library of the Standard ML of New Jersey contains an atom type that does the same thing. Objective-C's selectors, which are mainly used as method names, are interned strings.
Objects other than strings can be interned. For example, in Java, when primitive values are boxed into a wrapper object, certain values (any boolean, any byte, any char from 0 to 127, and any short or int between −128 and 127) are interned, and any two boxing conversions of one of these values are guaranteed to result in the same object.〔(Java conversions )〕
==History==
Lisp introduced the notion of interned strings for its symbols. Historically, the data structure used as a string intern pool was called an 'oblist' (when it was implemented as a linked list) or an 'obarray' (when it was implemented as an array).
Modern Lisp dialects typically distinguish symbols from strings; interning a given string returns an existing symbol or creates a new one, whose ''name'' is that string. Symbols often have additional properties that strings do not (such as storage for associated values, or namespacing): the distinction is also useful to prevent accidentally comparing an interned string with a not-necessarily-interned string, which could lead to intermittent failures depending on usage patterns.

抄文引用元・出典: フリー百科事典『 ウィキペディア(Wikipedia)
ウィキペディアで「String interning」の詳細全文を読む



スポンサード リンク
翻訳と辞書 : 翻訳のためのインターネットリソース

Copyright(C) kotoba.ne.jp 1997-2016. All Rights Reserved.